﻿using Abp.AutoMapper;
using Batman.Cms.Domains;
using Microsoft.AspNetCore.Mvc;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace Batman.Cms.Controllers.Inputs
{
    [AutoMap(typeof(ArticleType))]
    public class CreateArticleTypeInput
    {
        [Required(ErrorMessage = "请填写标题")]
        [MaxLength(255, ErrorMessage = "标题长度过长，长度限定在255字符内")]
        [DisplayName("标题")]
        public string Title { get; set; }

        [DisplayName("父级")]
        [UIHint("ArticleTypeTree")]
        public int? ParentId { get; set; }

        [MaxLength(255, ErrorMessage = "描述过长，长度限定在255字符内")]
        [DisplayName("描述")]
        [DataType(DataType.MultilineText)]
        [UIHint("TextArea")]
        public string Description { get; set; }

        //[HiddenInput(DisplayValue =false)]
        //[DisplayName("状态")]
        //public int Status { get; set; }
    }
}
